<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8" isELIgnored="false"%>
<%@ include file="/WEB-INF/views/shared/taglib.jsp"%>
<div class="table-responsive" style="overflow: auto;">
	<table class="cntable-tree table table-bordered tree-table">
		<thead>
			<tr>
				<th style="width: 80px;">序号</th>
				<th >文章分类名称</th>
				<th style="width: 200px;">访问方法路径</th>
				<th style="width: 80px;text-align:center">分类类型</th>
				<th style="width: 560px;text-align:center">描述</th>
				<th style="width: 60px;text-align:center">排序</th>
				<th style="width: 60px;">显示</th>
			</tr>
		</thead>
		<tbody>
			<tr>
				<td></td>
				<td></td>
				<td></td>
				<td class="text-center"></td>
				<td class="text-center"></td>
				<td class="text-center"></td>
				<td></td>
				<!-- <td class="text-left">
					<ul class="icons-list" style="padding: 0px;">
						<li><a href="javascript:allotMenu()"><i class="icon-menu6"></i>编辑</a></li>
					</ul>
				</td> -->
			</tr>
		</tbody>
	</table>
</div>

<script type="text/javascript">
$(function(){
	$(".table-responsive").css("max-height",$(window).height()-140);
	
	 $(".tree-table").fancytree({
	        extensions: ["table"],
	        table: {
	            indentation: 20,      // indent 20px per node level
	            nodeColumnIdx: 1
	        },
	        source: {
	            url: $.getVirtualPath()+"/admin/official/articalClassify/menuJson"
	        },
	        renderColumns: function(event, data) {
	            var node = data.node,
	            $tdList = $(node.tr).find(">td");

	            $tdList.eq(0).text(node.getIndexHier()).css("text-align","left");
	           /*  $tdList.eq(1).text(node.data.name); */
	            $(node.tr).attr("data-id",node.data.id);
	            $tdList.eq(2).text(node.data.functionURL);
	            $tdList.eq(3).text(node.data.type);
	            $tdList.eq(4).text(node.data.remark);
	            $tdList.eq(5).text(node.data.sortCode);
	            $tdList.eq(6).html(node.data.hidden==0?"<span class='text-danger'>否</span>":"<span class='text-success'>是</span>");
	          
	        },init:function(){
	        	$(".fancytree-icon").hide();
	        	bindTreeDblClick();       	
	        }
	    });
});

</script>